<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<script src="{{ctx}}/static/jquery/jquery-1.9.1.min.js"
	type="text/javascript"></script>
</head>
<body>
	<div id="privilageModal">
		<input type="hidden" id="appSelecterAppId" value="{{appId}}" />
		<p>
			选择应用 <select id="privilage-appSelecter" class="inline-form-control"
				onchange="appModalonchange(this.value,'{{roleID}}')">
				{{#appList}}
				<option value="{{id}}">{{app_name}}</option> {{/appList}}
			</select>
		</p>
		<div class="tabbable" id="tabbableDiv" style="display: none"></div>
	</div>
</body>
</html>
<script type="text/javascript">
	$(function() {
		var appId = "{{appId}}";
		var roleID = "{{roleID}}";
		appModalonchange(appId, roleID);
		$('#tabbableDiv').show();
	})
	//加载模块信息和权限信息页面
	function appModalonchange(appId, roleID) {
		$('#appSelecterAppId').val(appId);
		var loadurl = 'modules?roleID=' + roleID + "&appId=" + appId;
		$.get(loadurl, function(data) {
			$("#tabbableDiv").html(data);
		});
	}
</script>
